use Modern::Perl;
use Net::OpenSSH;
use Data::Dumper;
use Test::More;

my $flowcellid_path = "/seq_dir/Item/prenatal";
my $runstatus_path = "/flowcell_interface";

my $host = "huolh:huolinhe\@172.16.146.2";
my $ssh = Net::OpenSSH->new(
  $host,
  master_opts => [-o => 'StrictHostKeyChecking=no'],
  connect => 0,
);
note $ssh->check_master;
#my @return =  $ssh->capture("ls -lrt --time-style=\"+\%s\" " . $flowcellid_path . " | awk -F ' ' '{print \$6,\"\t\",\$7}'");
#note $return[1];
#note $return[1];
#my $return = $ssh->capture("ls -lrt --time-style=\"+\%s\" " . $flowcellid_path . " | awk -F ' ' '{print \$6,\"\t\",\$7}'");
#my @return = split "\n",$return;
#note $return[1];
my ($return,$err) =  $ssh->capture2("ls -Rl " . $runstatus_path . "/AHGYCTBGXX | grep '\\.'");
#note $return;
note $err;
#my @return = split "\n",$return;
#note $return[3];

done_testing();
